import { RootState } from "../utils/store.type";
import { Module } from "vuex";

const temperatureStatus: Module<any, RootState> = {
	namespaced: true,
	state: () => ({
		insideACHumidity: 0,
		insideACTemperature: 0,
		outsideACHumidity: 0,
		outsideACTemperature: 0,
		systemHumidity: 0,
		systemTemperature: 0,
		temperatureSystemState: 0,
	}),

	mutations: {
		statusUpdate(state, payload) {
			// console.log(state,payload);
			const json = JSON.parse(payload);
			Object.assign(state, json);
		},
	},

};

export 	default temperatureStatus;
